#version 330 core
layout (location = 0) in vec3 aPos; // 位置
layout (location = 1) in vec3 aColor; // 颜色
layout (location = 2) in vec2 aTexCoord; // 纹理坐标

out vec3 ourColor;
out vec2 TexCoord;

uniform mat4 transform; // 添加变换因子（变换矩阵）

void main()
{
    // 变换矩阵 和 位置坐标相乘
    gl_Position = transform * vec4(aPos, 1.0f);
    ourColor = aColor;
    TexCoord = aTexCoord;
}